package com.dianping.cat.configuration.server.transform;

import com.dianping.cat.configuration.server.IVisitor;
import com.dianping.cat.configuration.server.entity.ConsumerConfig;
import com.dianping.cat.configuration.server.entity.Domain;
import com.dianping.cat.configuration.server.entity.HarfsConfig;
import com.dianping.cat.configuration.server.entity.HdfsConfig;
import com.dianping.cat.configuration.server.entity.LongConfig;
import com.dianping.cat.configuration.server.entity.Property;
import com.dianping.cat.configuration.server.entity.Server;
import com.dianping.cat.configuration.server.entity.ServerConfig;
import com.dianping.cat.configuration.server.entity.StorageConfig;

public abstract class BaseVisitor
  implements IVisitor {
  public void visitConsumer(ConsumerConfig consumer) {
/* 17 */     if (consumer.getLongConfig() != null) {
/* 18 */       visitLongConfig(consumer.getLongConfig());
    }
  }


  
  public void visitDomain(Domain domain) {}


  
  public void visitHarfs(HarfsConfig harfs) {}


  
  public void visitHdfs(HdfsConfig hdfs) {}

  
  public void visitLongConfig(LongConfig longConfig) {
/* 36 */     for (Domain domain : longConfig.getDomains().values()) {
/* 37 */       visitDomain(domain);
    }
  }


  
  public void visitProperty(Property property) {}

  
  public void visitServer(Server server) {
/* 47 */     for (Property property : server.getProperties().values()) {
/* 48 */       visitProperty(property);
    }
    
/* 51 */     if (server.getStorage() != null) {
/* 52 */       visitStorage(server.getStorage());
    }
    
/* 55 */     if (server.getConsumer() != null) {
/* 56 */       visitConsumer(server.getConsumer());
    }
  }

  
  public void visitServerConfig(ServerConfig serverConfig) {
/* 62 */     for (Server server : serverConfig.getServers().values()) {
/* 63 */       visitServer(server);
    }
  }

  
  public void visitStorage(StorageConfig storage) {
/* 69 */     for (HdfsConfig hdfs : storage.getHdfses().values()) {
/* 70 */       visitHdfs(hdfs);
    }
    
/* 73 */     for (HarfsConfig harfs : storage.getHarfses().values()) {
/* 74 */       visitHarfs(harfs);
    }
    
/* 77 */     for (Property property : storage.getProperties().values())
/* 78 */       visitProperty(property); 
  }
}


/* Location:              /Users/hanfei/Documents/apache-tomcat-9.0.24/webapps/cat/WEB-INF/lib/cat-core-3.0.0.jar!/com/dianping/cat/configuration/server/transform/BaseVisitor.class
 * Java compiler version: 7 (51.0)
 * JD-Core Version:       1.0.7
 */